package com.danbay.cloud.device.api.service;

import com.danbay.cloud.device.api.dto.DevicePositionDto;
import com.danbay.framework.springnc.annotation.AutoController;
import com.danbay.framework.springnc.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestBody;

@AutoController
@RequestMapping("/device-service/position")
public interface IDevicePositionService {

    /**
     * 增加一个设备的位置（占坑）
     * @param devicePositionDto
     * @return 生成的ID值
     */
    @RequestMapping("/add")
    long addPosition(@RequestBody DevicePositionDto devicePositionDto);

    /**
     * 根据deviceId获取设备位置信息
     * @param deviceId
     * @return
     */
    @RequestMapping("/getByDeviceId")
    DevicePositionDto getPositionByDeviceId(String deviceId);


}
